<style>
    .timeline-content .row-sm {
        margin: 0px 10px 0px 10px;
    }
</style>
<div class="wrapper-md ng-scope mm-loading" ng-show="info.showName=='map'">
    <div class="timeline-content bg-white">
        <div class="row row-sm">
            <m-ui-select ng-if="false" prompt="请选择所属产品"
                         itme-list="LegendSys"
                         selected-item="info.sys"
                         select-item-fun="selectLegendSysItem(item)">
            </m-ui-select>
            <div class="col-sm-2 bg-white" ng-if="false">
                <accordion close-others="false">
                    <accordion-group heading="产品节点概况" is-open="true">
                        <div class="col-sm-12">
                            <div>
                                <p><b>名称:{{info.selectInfo.name || '空'}}</b></p>
                                <p><b>类型:{{info.selectInfo.mapType || '空'}}</b></p>
                            </div>
                            <p ng-if="(info.selectInfo.mapType=='MENU' || info.selectInfo.mapType=='PAGE' || info.selectInfo.mapType=='FEATURE' || info.selectInfo.mapType=='PROTOTYPE') && info.selectInfo.level !='1' && info.selectInfo.type!='PROTOTYPE'">
                                <button class="btn m-b-xs btn-sm btn-info btn-addon" ng-click="move()">
                                    <i class="fa fa-paw"></i> 移动
                                </button>
                            </p>
                            <p ng-if="(info.selectInfo.mapType=='MENU' || info.selectInfo.mapType=='SYS' ) && info.selectInfo.level < 3 ">
                                <button class="btn m-b-xs btn-sm btn-info btn-addon" ng-click="addMenu()">
                                    <i class="fa fa-plus"></i> 添加菜单
                                </button>
                            </p>
                            <p ng-if="info.selectInfo.mapType=='MENU'">
                                <button class="btn m-b-xs btn-sm btn-info btn-addon" ng-click="addPage()">
                                    <i class="fa fa-plus"></i> 添加页面
                                </button>
                            </p>
                            <p ng-if="info.selectInfo.mapType=='PAGE'">
                                <button class="btn m-b-xs btn-sm btn-info btn-addon" ng-click="addFeature('add')">
                                    <i class="fa fa-plus"></i> 添加功能点
                                </button>
                            </p>
                            <p ng-if="info.selectInfo.mapType!=undefined && info.selectInfo.mapType!='SYS' && info.selectInfo.type!='PROTOTYPE'">
                                <button class="btn m-b-xs btn-sm btn-info btn-addon" ng-click="delete()">
                                    <i class="fa fa-trash-o"></i> 删除
                                </button>
                            </p>
                            <png-if="info.selectInfo.mapType!=undefined && info.selectInfo.mapType!='SYS' && info.selectInfo.type!='PROTOTYPE'">
                                <button class="btn m-b-xs btn-sm btn-info btn-addon" ng-click="update()">
                                    <i class="fa fa-cog"></i> 修改标题
                                </button>
                            </p>
                            <p ng-if="info.selectInfo.mapType=='FEATURE' || info.selectInfo.mapType=='PROTOTYPE'">
                                <button class="btn m-b-xs btn-sm btn-info btn-addon" ng-click="findFeature()">
                                    <i class="fa fa-eye"></i> 查看功能点
                                </button>
                            </p>
                            <p ng-if="info.selectInfo.mapType=='FEATURE' || info.selectInfo.mapType=='PROTOTYPE'">
                                <button class="btn m-b-xs btn-sm btn-info btn-addon" ng-click="history()">
                                    <i class="fa fa-mail-reply"></i> 历史记录
                                </button>
                            </p>
                        </div>
                    </accordion-group>
                </accordion>
            </div>
            <div class="col-sm-12" style="border: 1px solid #ffffff">
                <winit-feature-map ng-if="!info.isSort" map-datas="info.mapDatas" blur="selectMap(info)"
                                   diagram-scope="info.diagramScope"
                                   search="info.search" move-fun="move()" add-menu-fun="addMenu()"
                                   add-page-fun="addPage()" add-feature-fun="addFeature('add')" remove-fun="delete()"
                                   edit-fun="update()" find-feature-fun="findFeature()" history-fun="history()"
                                   sort-fun="toSort()" select-sys-fun="selectLegendSysItem(item)"></winit-feature-map>
                <winit-sort ng-if="info.isSort" datas="info.childs" show-key="name" key="id"
                            commit-fun="sortNode(list);"></winit-sort>
            </div>
            <div ng-if="isUserCanOperateByRole()">{{info.selectInfo}}</div>
        </div>
    </div>
</div>
<div class="row">
    <div class="col-sm-12 mm-loading-icon" style="text-align: center; display: none; padding-top: 25%;">
        <i class="fa fa-spinner fa-spin fa-4x fa-fw" style="color: rgb(158, 149, 149);"></i>
    </div>
</div>

<div class="wrapper-md ng-scope mm-loading" ng-if="info.showName=='find'">
    <div class="timeline-content bg-white">
        <div class="row row-sm">
        </div>
        <div class="col-sm-12">
            <winit-feature-panel ng-if="info.featureInfo.type !='PROTOTYPE'" req-id="-1" feature-id="info.featureId"
                                 sys="info.sys.value" selected-branch="info.featureInfo" do-compare="true"
                                 show-header="false"></winit-feature-panel>
            <winit-prototype-panel ng-if="info.featureInfo.type =='PROTOTYPE'" req-id="-1" feature-id="info.featureId"
                                   sys="info.sys.value" selected-branch="info.featureInfo" is-master="true"></winit-prototype-panel>
        </div>
    </div>
</div>

<div class="wrapper-md ng-scope mm-loading" ng-if="info.showName=='history'">
    <div class="timeline-content bg-white">
        <div class="row row-sm">
            <div class="col-sm-2 bg-white">
                <accordion close-others="false">
                    <accordion-group heading="产品节点概况" is-open="true">
                        <div class="col-sm-12" style="">
                            <div>
                                <p>
                                    <b>名称:{{info.featureName || "页面"}}</b>
                                </p>
                                <p>
                                    <b>版本:{{info.historySelectInfo.name}}</b>
                                </p>
                                <!--  <p>
                                     <b>最新:{{info.selectInfo.name}}</b>
                                 </p>
                                 <p>
                                     <b>包含:{{info.selectInfo.name}}</b>
                                 </p> -->
                            </div>
                        </div>
                    </accordion-group>
                    <accordion-group heading="版本比较" is-open="true">
                        <div class="col-sm-12" style="margin-bottom: 10px;">
                            <m-ui-select prompt="请选择版本"
                                         itme-list="info.flowVersions"
                                         selected-item="info.sltPrevItem">
                            </m-ui-select>
                        </div>
                        <div class="col-sm-12" style="margin-bottom: 10px;">
                            <m-ui-select prompt="请选择版本"
                                         itme-list="info.flowVersions"
                                         selected-item="info.sltNextItem">
                            </m-ui-select>
                        </div>
                        <div class="col-sm-12">
                            <button class="btn btn-default col-sm-12 btn-info" ng-click="compareHistory()">比较</button>
                            <button class="btn btn-default col-sm-12 btn-primary" ng-click="view()"
                                    ng-show="info.showVersion">返回视图
                            </button>
                        </div>
                    </accordion-group>
                </accordion>
            </div>
            <div class="col-sm-10" style="border: 1px solid #ffffff">
                <winit-history-feature-map ng-show="!info.showVersion" datas="info.datas"
                                           blur="select(info)"></winit-history-feature-map>
                <winit-feature-panel ng-if="info.showVersion && info.selectInfo.type !='PROTOTYPE'" panel-type="false"
                                     read-only="false" show-compare="false" prev-data="info.prevPanel"
                                     next-data="info.nextPanel"></winit-feature-panel>
                <winit-prototype-panel ng-if="info.showVersion && info.selectInfo.type =='PROTOTYPE'" panel-type="false"
                                       read-only="false" show-compare="false" prev-data="info.prevPanel"
                                       next-data="info.nextPanel"></winit-prototype-panel>
            </div>
        </div>
    </div>
</div>
<winit-settings btn-list="settings.btnEle"></winit-settings>